package middol.event

import grails.converters.JSON
import grails.events.annotation.Publisher
import grails.events.annotation.Subscriber
import grails.gorm.transactions.Transactional
import groovy.transform.CompileStatic
import middol.global.BusinessException
import middol.test.Test
/**
* @Description:    service方法监听
* @Author:         zhangjiayu@middol.com
* @CreateDate:     2020/10/23 10:36
* @Version:        1.0
*/
@CompileStatic
class TestEventService {
    @Transactional
    @Subscriber
    def test(Test test) {
        println "2222222222222222: ${test as JSON}"
        throw new BusinessException("event test....")
    }
}
